import request from '@/utils/myAioxs'


export function getMeun(data) {
  return request({
    url: '/index/v1/app-column',
    method: 'get',
    data
  })
}

export function getClientLogin(appId) {
  return request({
    url: `/cas/v1/client/login/${appId}`,
    method: 'post',
  })
}


export function getSwiper(data) {
  return request({
    url: '/index/v1/polling-ads',
    method: 'post',
    data
  })
}

export function getIndexAd(data) {
  return request({
    url: '/index/v1/ads',
    method: 'post',
    data
  })
}


export function getRecommendCourses(limit) {
  return request({
    url: '/index/v1/recommend-courses',
    method: 'get',
    params:{
      limit
    }
  })
}
export function getAppTypeList(pid) {
  return request({
    url: `/course/v1/app/type-list/${pid}`,
    method: 'get',
  })
}
export function saveLearn(data) {
  return request({
    url: `/user-learn/v1/save`,
    method: 'post',
    data
  })
};
export function getNoticeList(limit) {
  return request({
    url: '/index/v1/notice-list-new',
    method: 'get',
    params:{
      limit
    }
  })
}
export function getOfficialtrainingList(limit) {
  return request({
    url: '/index/v1/official-training-list',
    method: 'get',
    params:{
      limit
    }
  })
}

export function getTeacherList(limit) {
  return request({
    url: '/index/v1/teacher-list.cache',
    method: 'get',
    params:{
      limit
    }
  })
}
export function getSpecialSubjects(limit) {
  return request({
    url: '/index/v1/special-subjects',
    method: 'get',
    params:{
      limit
    }
  })
}
export function getCommonList(limit) {
  return request({
    url: `/common/v1/question/index-list/${limit}`,
    method: 'get',
  })
}

export function getAnonymousList(data) {
  return request({
    url: `/user-notice/v1/get-anonymous-list`,
    method: "post",
    data,
  });
}
export function getNoAnonymousList(data) {
  return request({
    url: `/user-notice/v1/get-list`,
    method: "post",
    data,
  });
}
export function setUserNoticeRead(data) {
  return request({
    url: `/user-notice/v1/read`,
    method: "post",
    data,
  });
}
